home *** CD-ROM | disk | FTP | other *** search
Text File | 1994-07-26 | 23.3 KB | 501 lines | [TEXT/MPS ] |
- ========================================
- MacsBug Release Notes and Bedtime Tales
- by Jim Murphy and Dave Lyons
- ========================================
-
- • 6.5d9 - TOTALLY NEW STUFF
- -----------------
- Added the DMA command (dump memory in ASCII). The syntax is just like DM.
-
- Added .S suffix ("strip"). For example, PC.S is the same as PC if you are
- in 32-bit MMU mode, or (PC & 0x00FFFFFF) if you are in 24-bit MMU mode.
- MacsBug actually calls the StripAddress trap to implement this.
-
-
- ENHANCEMENTS
- ------------
- When you break into MacsBug at boot time by holding down the Control key, now
- it shows a more enlightening message. Hopefully this will stop people from
- writing up bugs that say "I rebooted with the control key held down, and I got
- a User Break!"
-
- When you break into MacsBug during boot, it displays the name of the currently-
- loading extension, if any.
-
- Command lines consisting only of "G", "T", or "S" do not appear in the command
- line history (Command-V / Command-B). The side-effect is that Command-G, -S,
- and -T do not enter anything into the command line history.
-
- The SET command now displays its syntax if you tell it something stupid.
-
- "HZ" shows "Mod" for Modern Memory Manager heaps (it used to say "Fig").
-
- The "WH" command, and others, can determine that an address is "inside MacsBug".
-
- The "DV" command includes some credits. "dv v" shows just the version, with
- no credits. MacsBug gets its version from its 'vers' 1 resource.
-
- The CurApName display uses an ellipsis character to truncate long names, rather
- than an underscore.
-
- Added an 8-bit-deep blitter (speeds up display on video cards that cannot switch
- to 1-bit mode). Made the one-bit blitter faster, too. Made scrolling up and
- down faster for all bit depths.
-
-
- MACROS
- ------
- Changed the maximum command line length to 250 (was around 90 before). So now you
- can have very long macro expansions.
-
- Added a macro called "StdLog" (standard log), which is great for writing up bug
- reports. It creates a log file full of info that system software engineers like
- (stack crawls, register dump, configuration info, etc).
-
- Lots of random cleanups of the macros. Removed redundant macros.
-
- Changed "da" and "dd" macros to "DApp" and "DDrvr", because "da" and "dd" are valid
- hex numbers.
-
-
- DISASSEMBLY
- -----------
- Trap vector names now show up in disassembly (and elsewhere) just as if you had a
- macro mapping into every address in the trap dispatch table. For example,
- MOVEA.L $06F4,A0 now disassembles as MOVEA.L jCacheFlush,A0. The trap is vCacheFlush,
- but the "v" (for vector) gets automatically changed to a "j" (for jump).
-
- The forms JSR ([$xxxx]) and JSR ([$xxxx],$yyyy) now support macro-style symbols for
- the $xxxx values.
-
- (Of course, do NOT use trap-table addresses in application code, but when you come
- across the system doing so, it's much easier to see what's going on now.)
-
- Fixed bugs in selector comparison (it was not always sign extending correctly).
-
- Disassembly now recognizes a CLR.W before a trap word as setting up selector with
- value zero.
-
- The PC disassembly window refreshes when you change D0-D7, A0-A7, SR, or PC. It
- was only refreshing on PC changes, but the others also affect the disassembly,
- because of symbolic info on JSR (Ax), "will branch" messages, and "will loop" (DBxx)
- messages.
-
-
- TRAP NAMES
- ----------
- Generally brought tons of traps and selectors up to date and made them better.
-
- Updated PowerMgrDispatch stuff to match WWDC 94 Technology CD document. However,
- MacsBug can't handle the different variants of OS-range traps having different names
- and different selectors, so the $A085 trap disassembles strangely. The $A685
- (PowerMgrDispatch) stuff is all there, but it (incorrectly) shows up for all variants
- ($A085, $A285, $A485, as well as $A685).
-
-
- DCMDS
- -----
- Several commands now draw bullet characters in place of all control characters in
- strings (affects 'file' showing Return characters in filenames, for example).
-
- Gestalt command dumps all Gestalt selectors. Supports System 7.5 Gestalt table format
- as well as older versions.
-
- The 'rd' command now shows an asterisk after any handle that has been purged. It also
- accepts capital letters for the options.
-
-
- BUG FIXES
- ---------
- Fixed some random memory accesses that were happening on non-Color QuickDraw machines
- during MacsBug startup. This was causing the mouse to freeze in one or two directions
- on a Mac Plus.
-
- Fixed trashing of D3 and A2 in BlitCharOneBit and BlitCharEightBits.
-
- Changed PBControlSync to PBStatusSync because we were trying to do a cscGetMode
- instead of a cscSetMode. (Affects compatibility with certain video drivers.)
-
-
- • 6.5d8 TOTALLY NEW STUFF
- -----------------
-
- Over the last few releases, we've worked to make MacsBug a bit more user-
- configurable and customizable. However, these configuration options have
- thus far been limited to setting bits in a preference resource, which
- doesn't allow for many on-the-fly changes. We've added a new general-purpose
- command that will enable behaviour changes any time you wish. The new command,
- SET, will be able to take a variety of options. The first is the new
- "ScrollPrompt" feature. By entering a command such as, "SET SCROLLPROMPT OFF",
- MacsBug can be told to never wait for a key if a new page of the scrollback
- history has become filled. Other variants of the new command are shown in
- the built-in help. In the future you'll find lots of other cool things you'll
- be able to do.
-
- There's now a 512-byte scratch memory area within MacsBug that's available for
- whatever you like. It's called "PlayMem" (TMON user's will recognize this), and
- can be used within any expression. The constant will evaluate to the address of
- the beginning of the buffer area.
-
- A-TRAP DISASSEMBLY
- ------------------
-
- Removed bogus duplicate A-trap name for StdOpcodeProc (it's really $ABF8;
- it was also in the table as $ABC8).
-
- Fixed vFileReal to be vFileRead.
-
- Unused/unknown A-traps now disassemble as "DC.W $Axyz" instead of "TB z" or "OS z".
-
- Lots of new names have been added to previously existing selectors, but they are
- too numerous to go into here.
-
- All calls have been updated to the more verbose new Inside Macintosh naming
- conventions. All old versions still work through the magic of macros.
-
- Disassembling selector-based calls is now much smarter when it comes to identifying
- the correct call. When it looks back up the code stream to identify the selector
- value, it is more knowledgeable about the various MOVE immediate instructions.
- It no longer unhelpfully interprets random data as selector values.
-
- A-TRAP TRACING
- --------------
-
- It now correctly works again (no more _Open calls). It'll be more verbose in the
- future, but at least it now does what it did before.
-
- A-TRAP RECORDING
- ----------------
-
- Versions of MacsBug from 6.4 through 6.5d6 had a serious bug that appeared
- during A-Trap recording. When recording OS calls, we save the first 8 bytes
- pointed to by register A0, for display by the 'ATP' command. In the
- instances that A0 isn't an input parameter to the trap, and contains an
- invalid pointer (outside of valid memory on the target machine), MacsBug
- takes the precaution of installing a special bus error handler when it
- attempts to copy the data. However, previous versions improperly installed
- the handler (they hooked on top of two vectors, both of which were wrong).
- Thus, if a bus error occurred during the copy, MacsBug's primary handler
- would take control and display the error to the user, which was completely
- the wrong thing to do.
-
- HEAP DUMPS
- ----------
-
- When MacsBug dumps heaps that contain resources from open files, it is more
- careful in showing the error, "** bad rsrc map**".
-
- SCROLLBACK HISTORY
- ------------------
-
- The supported sizes of the scrollback history buffer have been changed to
- allow for a much larger buffer. Previously, only values of 0-32767 were
- supported, which specified the requested history buffer size in bytes. 0
- and 1-255 indicated that no history buffer should be allocated at all. Now
- values of 32768-65535 are valid, and 1-255 indicate special larger sizes.
- For 1-255, the value is multiplied by 64K, giving a range of 64K-16MB in
- 64K increments. Zero is still supported to allocate no buffer.
-
- (Page Up/Down mostly work, but there are still a few problems.)
-
- SYMBOL LOOKUP
- -------------
-
- If we break into MacsBug with VM enabled and paging isn't safe, we now act
- as though symbol display is turned off (via the "SX" command). Doing symbol
- lookups causes heaps throughout memory to be walked, possibly causing quite
- a bit of paging to take place. This is an extremely evil thing for a low-level
- debugger to do, and we're trying to be as nice as we possibly can.
-
- COMMAND-: SYMBOL LOOKUP
- -----------------------
-
- Fixed the infamous C++ unmangled symbols problem. MacsBug would show you the
- symbol in the Command-: window, but it wouldn't evaluate it unless you stripped
- the quotes from the unmangled name. This is no longer necessary.
-
- If you hold down the Option key when pressing return after selecting a symbol,
- the address of the symbol is entered onto the command line, rather than the
- symbol itself. However, if you navigate the list by typing and use this feature,
- it used to dump a semi-random address. This has been fixed.
-
- MEMORY DISPLAY
- --------------
-
- When displaying addresses that correspond to bus error vectors (0x00000008
- through 0x0000000B and VBR+0x00000008 through VBR+0x0000000B), we now show the
- previous vector addresses, not the MacsBug handlers. This should make it a bit
- easier to find your code if you replace either bus error vector.
-
- The built-in font now contains the entire high-ASCII character set for a more
- useful display ($20 through $D9). You can now type all of these characters as
- well.
-
- Template related code has been fixed to not cause address errors on 68000
- machines.
-
- STACK CRAWL
- -----------
-
- When determining if a given address is really a return address as we walk up
- the stack, we no longer cause page faults. This should make the stack crawl
- commands a bit more useful when used in an environment where VM paging is not
- safe.
-
- BREAKPOINTS
- -----------
-
- If you set or clear a breakpoint, the disassembly display area above the command
- line will be redrawn, in case there's an upcoming break that's already been called
- out with a bullet alongside an address.
-
- REGISTERS
- ---------
-
- Code dealing with setting and displaying the Status Register now realizes it is
- 16-bits in length and always has been. This bug has been present since at least
- 6.2.
-
- LOGGING
- -------
-
- If you attempt to turn the log on or off when the file system is busy, MacsBug
- will warn you that this is impossible. This helps a bit in preventing data on
- your drives from being corrupted, but there's still a huge architectural flaw
- in the whole thing (ask me about my 400 MB I had to restore from tape...). In a
- nutshell, it works, but just barely.
-
- MISCELLANEOUS
- -------------
-
- Keyboard repeat rates have been fixed for the Mac Plus (it no longer spews tens of
- keys for each individual keypress).
-
- DCMDS
- -----
-
- RD - The help explains what the various attributes flags are. Map $0003 shows up
- with a special name now, instead of garbage (it makes ROM resources override the
- system). The command aborts much faster now if you press a key. Fixed problems of
- excess filtering when you used -f along with -t or -i (or when you used -i at all).
-
-
- • 6.5d7 - NOTE: This version sorta-kinda exists. It was released to a small number of
- individuals related to the System 7.5 and PowerPC v0 teams, but it was never
- generally released. There are actually a few different versions of d7, so it was
- decided the best thing to do was say, "don't use it - use 6.5d8 instead".
-
-
- • 6.5d6 - HEAP SCRAMBLING
- ---------------
-
- It works again, what more can I say? Starting with MacsBug 6.5d1 (before I
- took over the project), the Heap Scramble command was broken for all Memory
- Managers, including 24-bit, 32-bit, and Modern. It now works properly for
- the classic Memory Managers, and for the first time, is works equally well
- for Modern-style blocks and heaps.
-
- If you break into MacsBug because of a Heap Scramble failure, the proper
- tool name will be displayed. It used to try to display the names of
- selector-based tools, but failed, since we only scramble on a few real
- A-Traps. All you would see is a bunch of gunk, but no harm was done.
-
- EXCEPTION HANDLER
- -----------------
-
- While you're sitting at the command line, MacsBug has its own bus error
- handler installed. If something goes wrong, you'll generally see the
- message "Unable to access that address". However, if the exception was
- generated by code within MacsBug, finding the code that actually caused
- the exception was quite difficult. Now MacsBug displays some simple
- diagnostic information, including the Program Counter of the code that
- really caused the exception.
-
-
- • 6.5d5 - With the addition of "User Debugger Prefs" there's been a lot of confusion.
- So, in an effort to reduce this, and make absolutely sure each version of
- MacsBug has available the resources it needs to run, "User Debugger Prefs"
- is no longer supported, and the Debugger Prefs resources now exist within
- MacsBug itself (that's why it's now almost 400K on disk). All custom
- resources should go into Debugger Prefs, and MacsBug's resources should be
- left alone.
-
- - We now check for duplicate dcmds at startup and display their names.
- You'll see this list (if you have any duplicates) the first time you enter
- MacsBug.
-
- - Increased the number of words that DH can disassemble at once from 6 to 18.
-
- - Fixed a minor bug with A-Trap actions. If you had an action set on any
- selector, removed it, and then did an 'ATSS', 'ATB', or 'ATHC' with no
- parameters, the range start would appear to be the old selector. We were
- setting the selector flag and value fields in the trap record if the
- selector was specifically described, and we weren't clearing them
- otherwise. Since the new action record was in the location of the old
- record, the uninitialized fields were used.
-
- - When an A-Trap Trace is displayed, we now show the name of the selector
- instead of its parent A-Trap, if necessary. This means if you do an 'ATT'
- on _GetFrontProcess, for instance, when the trace information is dumped
- into the MacsBug history, the trap name will be _GetFrontProcess instead
- of its parent, _OSDispatch.
-
- - When you break into MacsBug because of an A-Trap action on a selector-
- based call, the selector name will be displayed instead of the parent
- A-Trap name.
-
- - We now mostly work on 68000 machines (again). If the trap name STR#
- resources were an odd length, we'd address error at startup while trying to
- load them. We now pad them in memory to be word-aligned, just like all of
- our other structures (would you belive I solved this one with MicroBug?)
-
- - Updated the TestDcmd application:
- -Made the font draw like they do Macsbug (you get space through ~, plus
- ≈ and † and … and •, and everything else is a bullet).
- -Made Command-G = Command-Q.
- -Made ? = help.
- -When the screen is paused, still proccess events except for non-Command
- keypresses.
- -Made space continue as well as return/enter.
- -Made Clear/Ctrl-X clear the command line.
-
- - In the 'file' dcmd, made some columns wider and fixed the filename-prefix
- feature.
-
- - In the 'drvr' dcmd, widened the driver name field so you can see longer
- names without truncation.
-
-
- • 6.5d4 - Fixed command line history to not get confused when you repeat a previous
- command with Command-V or Command-B. It wasn't resetting the history marker
- when you entered a new command that exactly matched the last command, so you
- could only repeat the last command once, and then the last command would
- become the line prior to that.
-
- - Fixed a nasty bug dealing with most break action commands. If you set more
- than one A-Trap break, A-Trap Step Spy, or Breakpoint, each new break
- would overwrite the previous, corrupting it. The record that could become
- the most damaged was that of the Step Spy, which could cause MacsBug to
- become way confused the next time it walked the table. Almost not broken
- just isn't good enough for me!
-
- - Breaking on selector-based calls now works! If you want to break on one of
- these calls, ATB (and all of its variants) now use the same structures
- that provided for the disassembly of selector-based calls. I've slightly
- modifed the displays for the ATB and ATD commands to account for the fact
- that you're not necessarially breaking on all calls of a specific ATrap.
- It now shows you both the selector name and ATrap name, plus the ATrap
- and selector values.
-
- The way that this works is cool enough that you can still provide a
- conditional break expression which allows for even more fine-tuning of
- when to break. So something like, "ATB _GetFrontProcess D0.w=-1" will
- work, even though in most cases it's not really that useful, since in this
- case it's already implicitly breaking on the expression "(SP)^.w=39".
-
- If there are calls that you can't seem to break on, there are a number of
- reasons why. The most-likely is that I simply haven't yet added calls of
- that particular A-Trap to the prefs file (although it could be there and
- I simply screwed up the selector).
-
- - Because of the above, I've removed lots of redundant macros from the
- Debugger Prefs file (the ones that did the "ATB _CallName d0.w=#x").
-
- - MacsBug now supports a new preference resource (which can be located in
- either the User or standard Debugger Prefs file) of type 'mxpr'. Its
- sole purpose in life right now is to support some cool power-user
- "danger prefs" that support doing things a bit faster. There's a ResEdit
- TMPL provided in Debugger Prefs which allows you to edit the various
- defined bits. I recommend copying it into your User Debugger Prefs file
- (since that's why I added the file anyway) and changing it there.
- I'll probably eventually add new commands to MacsBug itself that let you
- modify the more useful preferences at run-time.
-
- - Two preferences bits support disabling the little-known self-checksum
- feature. Normally, after you execute any command from the command-line,
- MacsBug performs a checksum on all of its code, and warns you if it was
- modified. While this can be quite useful, most will never see the message.
- The annoying bit is that this takes a heck of a lot of time (MacsBug's
- code is about 100K in memory right now, so on my analyzer-bait Mac II the
- checksum takes 151.1ms).
-
- Now you can selectively disable the checksum in all cases by setting the
- "Never checksum MacsBug code" bit. If you'd like some assurances that
- MacsBug wasn't stomped on, you can set the "Only checksum code on entry"
- bit. When you enter MacsBug, either through a DebugStr or Debugger trap
- or via an NMI, it will perform the checksum. Note that the "never" bit
- overrides the setting of this bit.
-
- - One other bit has quite a noticeable effect on stepping and tracing with
- a machine that has a single monitor (or one that has MacsBug on its main
- device). This bit, "Don't swap screen if stepping", does just what it
- says. If you step with this bit set, MacsBug will never swap the display
- to show the original video buffer. This is slightly dangerous if you're
- stepping code that does draw directly to the screen (because the video
- card could have been in an entirely different mode than what it is when
- you're in MacsBug). However, it will have no effect if you trace over a
- QuickDraw trap, because the display _will_ be swapped in that case. Use
- this, it's waaaaay cool. And faster too.
-
- - Added macros for GSBug users (me) who just can't seem to type the right
- commands while in MacsBug. STB now works for ATB, CTB now works for ATC,
- and SH works for ATD (actually, these were added in 6.5d2, but I neglected
- to mention it then).
-
- - Twiddled the message for MCC when a macro is cleared. It now says,
- "Macro '<macroname>' cleared" instead of "'<macroname>' cleared.
- Dave freaked for a second when he typed "MCC heap", and MacsBug responded
- with "Heap cleared". :-)
-
- - Modified the 'vbl' dcmd to use uppercase in hex displays (we're picky
- people). It now dumps all of the non-empty slot VBL queues in addition to
- the standard queue.
-
-
- • 6.5d3 - Modified to load selector traps, macros, templates, and DCMDs from two files.
- We still load from Debugger Prefs, however, we now support a new file, "User
- Debugger Prefs". This allows you to paste all of your custom resources into
- the User file, and not worry about having to copy resources when you upgrade
- the standard DP file. We also now allow 'mxbi', 'mxbc' and 'KCHR' resources
- to be found in the User file to override the default ones we ship in the DP file.
-
- This change causes all of the above mentioned resources to be loaded in
- the opposite order that they were in previous versions (all types of
- resources are now loaded increasing from index 1).
-
- - The Clear key and Control-X now clear the entire command line and move the
- cursor to the left edge.
-
- - The key delay to repeat and repeat rate have been (hopefully) equalized
- for all machines. No more annoying slowness on fast machines.
-
- - Sped up the one-bit single character blitter to be as fast as it was in
- 6.2.2. The overall string drawing throughput is slower than 6.2.2, but
- it'll probably get faster in later versions. As compared to 6.5d2, however,
- the blitter is 6.3 times faster, which is quite cool.
-
-
- • 6.5d2 - Added a new resource type, 'mxst', to Debugger Prefs for the display of
- toolcall names that are selector-based (ie. HFSDispatch). This allows you
- to see the names of the real calls, rather than simply the dispatch trap name.
- Eventually you'll be able to break on the names, instead of having to define
- macros like you do now. I added a bunch of toolcall names to Debugger Prefs,
- but there are certainly some missing, and there may be some that are incorrect.
-
-
- • 6.5d1 - Moved toolbox and OS trapnames into STR# resources in the Debugger Prefs
- file. Added initial support for the Modern Memory Manager.
-
-
- • 6.4a9 - Fix breakpoints in ROM to actually break.
- - Fix to not mess with the interupt levels if we enter MacsBug in user mode.
-
-
- • 6.4a8 - Fix problem with the calculation of video slot address causing some
- machines to not boot.
- - Remove indication of bit depth from MacsBug screen. This bit depth was
- indicating what the depth MacsBug was operating in not the depth of the
- monitor when running normally.
-
-
- • 6.4a7 - Support for multibit video.